<?php
namespace module\base\controller;

use houdunwang\request\Request;
use module\base\model\BaseContent;
use module\HdController;

class Wx extends HdController
{

    public function index()
    {

        return $this->template();
    }

    public  function  post(){
        $baseModel=new BaseContent();
        if(IS_POST){
            $post=Request::post();
//           回复内容 存入数据库
            $baseModel->save($post);
//            将basecontent的id存入post数据
            $post['module_id']=$baseModel['id'];
            $this->saveKeywords($post);
            return $this->setRedirect(url('wx.index'))->success('操作成功');
        }
        return $this->template();
    }
}